<%--
    Copyright 2010 mazhao.

    Licensed under the Apache License, Version 2.0 (the "License");
    you may not use this file except in compliance with the License.
    You may obtain a copy of the License at

         http://www.apache.org/licenses/LICENSE-2.0

    Unless required by applicable law or agreed to in writing, software
    distributed under the License is distributed on an "AS IS" BASIS,
    WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    See the License for the specific language governing permissions and
    limitations under the License.
    under the License.
    Document   : changepassword.jsp
    Created on : Oct 24, 2010, 10:26:29 PM
    Author     : mazhao
--%>

<%@page contentType="text/html" pageEncoding="UTF-8" %>
<%@ taglib prefix="s" uri="/struts-tags" %>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">

<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <title><s:text name="changepwd.html.title"/></title>
    <script type="text/javascript">
        $(document).ready(function() {
            $("#changepwdForm").validate({
                rules: {
                    username:    "required",
                    oldPassword: "required",
                    password:    "required",
                    rePassword: {
                        required: true,
                        equalTo:  "#password"
                    }
                }
            });
        });
    </script>
    <style type="text/css">
        form label.error {
            background: white;
            border: none;
            font: normal;
        }
    </style>
</head>
<body>
<h1><s:text name="changepwd.title"/></h1>
<s:form method="post" namespace="/customer" action="changepwd" id="changepwdForm" cssClass="alt" cssStyle="width:550px;">
    <s:textfield name="username" key="changepwd.username" id="username"/>
    <s:password name="oldPassword" key="changepwd.oldpassword" id="oldPassword"/>
    <s:password name="password" key="changepwd.newpassword" id="password"/>
    <s:password name="rePassword" key="changepwd.newpassword2" id="rePassword"/>
    <s:submit value="Change"/>
</s:form>
</body>
</html>
